/**
 * @file   std_util.hpp
 * @author wolfhead <wolfhead@wolfhead-laptop>
 * @date   Sat Aug 27 12:59:56 2011
 * 
 * @brief  
 * 
 * 
 */

#ifndef ACAPELAA_UTIL_STD_UTIL_HPP
#define ACAPELAA_UTIL_STD_UTIL_HPP

namespace acapella
{

class StdUtil
{
public:

    template<typename Value>
    static void GetMapKeys(
        const std::map<Value>& map,
        std::vector<Value>& vec
        )
    {
        vec.clear();
        vec.reserve(map.size());

        for (std::map<Value>::const_iterator it = map.begin();
             it != map.end();
             ++it)
        {
            vec.push_back(it->first);
        }
    }

    template<typename Value>
    static std::vector<Value> GetMapKeys(const std::map<Value>& map)
    {
        std::vector<Value> vec;
        GetMapKeys(map, vec);
        return vec;
    }


};



}//namespace acapella

#endif
